cmake_minimum_required(VERSION 3.6)
project(cppdemo)

set(CMAKE_CXX_STANDARD 11)

#set(HOME ./lib)
#set(EXECUTABLE_OUTPUT_PATH ${HOME}/bin)
find_package(SQLite3 REQUIRED)
find_package(nlohmann_json REQUIRED)
include_directories(${SQLite3_INCLUDE_DIRS})
include_directories(./websocket/wskserver.h)
include_directories(./websocket/httpserver.h)
include_directories(./mongoose/mongoose.h)
include_directories(./sqllite/WSqlite.h)
message("sqllite3 found:" ${SQLite3_FOUND})
message("sqllite3 libraries:" ${SQLite3_LIBRARIES})
message("sqllite3 include: ${SQLite3_INCLUDE_DIRS}")
add_executable(cppdemo  main.cpp mongoose/mongoose.c sqllite/WSqlite.cpp websocket/wskserver.cpp websocket/httpserver.cpp
        websocket/myfriends.cpp
        websocket/myfriends.h)
target_link_libraries(cppdemo LINK_PUBLIC sqlite3  nlohmann_json::nlohmann_json)